From: Andrew Zaech Date: Sun, 29 Sep 2024 22:43:15 +0000 (+0000) Subject: popupSwitchMenuItem: Emit correct switch state with toggled signal X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~194^2^2~19 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=9bdc47625de2beb9af33f9d1bd7194bf0fef42b2;p=gnome-shell.git popupSwitchMenuItem: Emit correct switch state with toggled signal The toggled signal was incorrectly emitting the pspec instead of the switch state. Closes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/7943 Part-of: (cherry picked from commit 7fe05f6bc9854f46f17c6db42ab9e9c3e9b4810c) --- diff --git a/js/ui/popupMenu.js b/js/ui/popupMenu.js index cf0406ca7..e0693709a 100644 --- a/js/ui/popupMenu.js +++ b/js/ui/popupMenu.js @@ -607,8 +607,8 @@ export const PopupSwitchMenuItem = GObject.registerClass({ this.checkAccessibleState(); } - _onToggled(sw, state) { - this.emit('toggled', state); + _onToggled() { + this.emit('toggled', this._switch.state); this.checkAccessibleState(); }